<template>
  <div class="left-menu">
    <el-menu
        router="router"
        :default-active="this.$route.path"
        default-active="2"
        class="el-menu-vertical-demo"
        >
      <el-menu-item  v-for="(item,i) in leftNavList" :key="i" :index="item.name">
        <i :class="item.icon"></i>
        <span slot="title">{{item.navItem}}</span>
      </el-menu-item>
    </el-menu>
  </div>
</template>

<script>
export default {
  name: "index",
  data(){
    return{
      leftNavList:[
        {name:'/home',navItem:'主页',icon:"el-icon-s-home"},
        {name:'/binding',navItem:'绑定银行卡',icon: "el-icon-s-finance"},
        {name:'/transfer',navItem:'转账',icon: "el-icon-s-promotion"},
        {name:'/flow',navItem:'交易流水查询',icon: "el-icon-s-data"},
        {name:'/recharge',navItem:'充值',icon: "el-icon-s-shop"},
        {name:'/withdraw',navItem:'提现',icon: "el-icon-s-ticket"},
        {name:'/userCenter',navItem: '个人中心',icon: "el-icon-user-solid"}
      ]
    }
  }
}
</script>

<style scoped>
.left-menu{
  margin-top: 50px;
}
</style>
